package com.lenovo.manufacture.net;

import okhttp3.OkHttpClient;
import retrofit2.Retrofit;
import retrofit2.adapter.rxjava2.RxJava2CallAdapterFactory;
import retrofit2.converter.gson.GsonConverterFactory;

public class RetrofitFactory {

    static public Retrofit getRetroFit() {
        return new Retrofit.Builder()
                .baseUrl(ApiService.BASE_URl)
                .addConverterFactory(GsonConverterFactory.create())
                .build();
    }

    static public ApiService getApiService() {
        return getRetroFit().create(ApiService.class);
    }
}
